﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Web;

namespace RTracker.Models.Common
{
    /// <summary>
    /// Class for AuthenticationContext, used to get and set values of AuthenticationContext properties.
    /// </summary>
    public class CAuthenticationContext
    {

        #region "Members Variables"
        private int m_nUserId;               // to store user id        
        private string m_strSessionKey;        // to store session key
        #endregion

        #region "Constructors"
        // default constructor
        public CAuthenticationContext()
        {
            m_nUserId = 0;
            m_strSessionKey = "";
        }
        // parameterized constructor
        public CAuthenticationContext(int nUserId, string strSessionKey)
        {
            m_nUserId = nUserId;
            m_strSessionKey = strSessionKey;

        }



        #endregion

        #region "Properties"

        /// <summary>
        /// Used to store user id
        /// </summary>
        public int UserId
        {
            get { return m_nUserId; }
            set { m_nUserId = value; }
        }

        /// <summary>
        ///  Used to store session key
        /// </summary>
        public string SessionKey
        {
            get { return m_strSessionKey; }
            set { m_strSessionKey = value; }
        }

        #endregion

    }
}